﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MeshGenerator.Core.Collections;

namespace MeshGenerator.Core
{  
    public abstract class Geometry
    {
        public event EventHandler Changed;

        protected Geometry()
        {
            vertexList.Changed += new EventHandler(vertexList_Changed);
        }

        void vertexList_Changed(object sender, EventArgs e)
        {
            if (Changed != null)
                Changed(this, new EventArgs());
        }
        
        ObservedList<Vertex> vertexList = new ObservedList<Vertex>();
        public ObservedList<Vertex> VertexData
        { 
            get 
            { 
                return vertexList; 
            } 
        }
    }
}
